/*
 * Copyright (c) 2025 李伟国
 * SQL-API is licensed under Mulan PSL v2.
 * You can use this software according to the terms and conditions of the Mulan
 * PSL v2.
 * You may obtain a copy of Mulan PSL v2 at:
 *          http://license.coscl.org.cn/MulanPSL2
 * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY
 * KIND, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
 * NON-INFRINGEMENT, MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE.
 * See the Mulan PSL v2 for more details.
 */
package com.moyu.sql.business.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import lombok.Data;
import org.springframework.web.bind.annotation.RequestMethod;

/**
 * 路由实体
 */
@Data
public class MoyuRouter {

    @TableId(value = "router_id", type = IdType.ASSIGN_ID)
    public String routerId;

    /**
     * 父级路由id
     */
    public String parentId;

    /**
     * sqlId
     */
    public String sqlId;

    /**
     * 参数组id
     */
    public String paramGroupId;

    /**
     * 路由名称
     */
    public String routerName;

    /**
     * 路由地址（相对地址）
     */
    public String routerPath;

    /**
     * 路由地址绝对路径
     */
    public String routerFullPath;

    /**
     * 是否是请求路由（而不是单纯的路径）
     */
    public Boolean isRequest;

    /**
     * 路由方法
     */
    public RequestMethod requestMethod;

    /**
     * 删除标志
     */
    @TableLogic
    public String delFlag;
}
